package models;

import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Date;
import java.util.Iterator;
import java.util.List;

public class DrCourtExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public DrCourtExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        protected void addCriterionForJDBCDate(String condition, Date value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            addCriterion(condition, new java.sql.Date(value.getTime()), property);
        }

        protected void addCriterionForJDBCDate(String condition, List<Date> values, String property) {
            if (values == null || values.size() == 0) {
                throw new RuntimeException("Value list for " + property + " cannot be null or empty");
            }
            List<java.sql.Date> dateList = new ArrayList<java.sql.Date>();
            Iterator<Date> iter = values.iterator();
            while (iter.hasNext()) {
                dateList.add(new java.sql.Date(iter.next().getTime()));
            }
            addCriterion(condition, dateList, property);
        }

        protected void addCriterionForJDBCDate(String condition, Date value1, Date value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            addCriterion(condition, new java.sql.Date(value1.getTime()), new java.sql.Date(value2.getTime()), property);
        }

        public Criteria andCourtidIsNull() {
            addCriterion("COURTID is null");
            return (Criteria) this;
        }

        public Criteria andCourtidIsNotNull() {
            addCriterion("COURTID is not null");
            return (Criteria) this;
        }

        public Criteria andCourtidEqualTo(String value) {
            addCriterion("COURTID =", value, "courtid");
            return (Criteria) this;
        }

        public Criteria andCourtidNotEqualTo(String value) {
            addCriterion("COURTID <>", value, "courtid");
            return (Criteria) this;
        }

        public Criteria andCourtidGreaterThan(String value) {
            addCriterion("COURTID >", value, "courtid");
            return (Criteria) this;
        }

        public Criteria andCourtidGreaterThanOrEqualTo(String value) {
            addCriterion("COURTID >=", value, "courtid");
            return (Criteria) this;
        }

        public Criteria andCourtidLessThan(String value) {
            addCriterion("COURTID <", value, "courtid");
            return (Criteria) this;
        }

        public Criteria andCourtidLessThanOrEqualTo(String value) {
            addCriterion("COURTID <=", value, "courtid");
            return (Criteria) this;
        }

        public Criteria andCourtidLike(String value) {
            addCriterion("COURTID like", value, "courtid");
            return (Criteria) this;
        }

        public Criteria andCourtidNotLike(String value) {
            addCriterion("COURTID not like", value, "courtid");
            return (Criteria) this;
        }

        public Criteria andCourtidIn(List<String> values) {
            addCriterion("COURTID in", values, "courtid");
            return (Criteria) this;
        }

        public Criteria andCourtidNotIn(List<String> values) {
            addCriterion("COURTID not in", values, "courtid");
            return (Criteria) this;
        }

        public Criteria andCourtidBetween(String value1, String value2) {
            addCriterion("COURTID between", value1, value2, "courtid");
            return (Criteria) this;
        }

        public Criteria andCourtidNotBetween(String value1, String value2) {
            addCriterion("COURTID not between", value1, value2, "courtid");
            return (Criteria) this;
        }

        public Criteria andCourtnameIsNull() {
            addCriterion("COURTNAME is null");
            return (Criteria) this;
        }

        public Criteria andCourtnameIsNotNull() {
            addCriterion("COURTNAME is not null");
            return (Criteria) this;
        }

        public Criteria andCourtnameEqualTo(String value) {
            addCriterion("COURTNAME =", value, "courtname");
            return (Criteria) this;
        }

        public Criteria andCourtnameNotEqualTo(String value) {
            addCriterion("COURTNAME <>", value, "courtname");
            return (Criteria) this;
        }

        public Criteria andCourtnameGreaterThan(String value) {
            addCriterion("COURTNAME >", value, "courtname");
            return (Criteria) this;
        }

        public Criteria andCourtnameGreaterThanOrEqualTo(String value) {
            addCriterion("COURTNAME >=", value, "courtname");
            return (Criteria) this;
        }

        public Criteria andCourtnameLessThan(String value) {
            addCriterion("COURTNAME <", value, "courtname");
            return (Criteria) this;
        }

        public Criteria andCourtnameLessThanOrEqualTo(String value) {
            addCriterion("COURTNAME <=", value, "courtname");
            return (Criteria) this;
        }

        public Criteria andCourtnameLike(String value) {
            addCriterion("COURTNAME like", value, "courtname");
            return (Criteria) this;
        }

        public Criteria andCourtnameNotLike(String value) {
            addCriterion("COURTNAME not like", value, "courtname");
            return (Criteria) this;
        }

        public Criteria andCourtnameIn(List<String> values) {
            addCriterion("COURTNAME in", values, "courtname");
            return (Criteria) this;
        }

        public Criteria andCourtnameNotIn(List<String> values) {
            addCriterion("COURTNAME not in", values, "courtname");
            return (Criteria) this;
        }

        public Criteria andCourtnameBetween(String value1, String value2) {
            addCriterion("COURTNAME between", value1, value2, "courtname");
            return (Criteria) this;
        }

        public Criteria andCourtnameNotBetween(String value1, String value2) {
            addCriterion("COURTNAME not between", value1, value2, "courtname");
            return (Criteria) this;
        }

        public Criteria andStatusIsNull() {
            addCriterion("STATUS is null");
            return (Criteria) this;
        }

        public Criteria andStatusIsNotNull() {
            addCriterion("STATUS is not null");
            return (Criteria) this;
        }

        public Criteria andStatusEqualTo(BigDecimal value) {
            addCriterion("STATUS =", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusNotEqualTo(BigDecimal value) {
            addCriterion("STATUS <>", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusGreaterThan(BigDecimal value) {
            addCriterion("STATUS >", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusGreaterThanOrEqualTo(BigDecimal value) {
            addCriterion("STATUS >=", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusLessThan(BigDecimal value) {
            addCriterion("STATUS <", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusLessThanOrEqualTo(BigDecimal value) {
            addCriterion("STATUS <=", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusIn(List<BigDecimal> values) {
            addCriterion("STATUS in", values, "status");
            return (Criteria) this;
        }

        public Criteria andStatusNotIn(List<BigDecimal> values) {
            addCriterion("STATUS not in", values, "status");
            return (Criteria) this;
        }

        public Criteria andStatusBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("STATUS between", value1, value2, "status");
            return (Criteria) this;
        }

        public Criteria andStatusNotBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("STATUS not between", value1, value2, "status");
            return (Criteria) this;
        }

        public Criteria andRemoteurlIsNull() {
            addCriterion("REMOTEURL is null");
            return (Criteria) this;
        }

        public Criteria andRemoteurlIsNotNull() {
            addCriterion("REMOTEURL is not null");
            return (Criteria) this;
        }

        public Criteria andRemoteurlEqualTo(String value) {
            addCriterion("REMOTEURL =", value, "remoteurl");
            return (Criteria) this;
        }

        public Criteria andRemoteurlNotEqualTo(String value) {
            addCriterion("REMOTEURL <>", value, "remoteurl");
            return (Criteria) this;
        }

        public Criteria andRemoteurlGreaterThan(String value) {
            addCriterion("REMOTEURL >", value, "remoteurl");
            return (Criteria) this;
        }

        public Criteria andRemoteurlGreaterThanOrEqualTo(String value) {
            addCriterion("REMOTEURL >=", value, "remoteurl");
            return (Criteria) this;
        }

        public Criteria andRemoteurlLessThan(String value) {
            addCriterion("REMOTEURL <", value, "remoteurl");
            return (Criteria) this;
        }

        public Criteria andRemoteurlLessThanOrEqualTo(String value) {
            addCriterion("REMOTEURL <=", value, "remoteurl");
            return (Criteria) this;
        }

        public Criteria andRemoteurlLike(String value) {
            addCriterion("REMOTEURL like", value, "remoteurl");
            return (Criteria) this;
        }

        public Criteria andRemoteurlNotLike(String value) {
            addCriterion("REMOTEURL not like", value, "remoteurl");
            return (Criteria) this;
        }

        public Criteria andRemoteurlIn(List<String> values) {
            addCriterion("REMOTEURL in", values, "remoteurl");
            return (Criteria) this;
        }

        public Criteria andRemoteurlNotIn(List<String> values) {
            addCriterion("REMOTEURL not in", values, "remoteurl");
            return (Criteria) this;
        }

        public Criteria andRemoteurlBetween(String value1, String value2) {
            addCriterion("REMOTEURL between", value1, value2, "remoteurl");
            return (Criteria) this;
        }

        public Criteria andRemoteurlNotBetween(String value1, String value2) {
            addCriterion("REMOTEURL not between", value1, value2, "remoteurl");
            return (Criteria) this;
        }

        public Criteria andCreatetimeIsNull() {
            addCriterion("CREATETIME is null");
            return (Criteria) this;
        }

        public Criteria andCreatetimeIsNotNull() {
            addCriterion("CREATETIME is not null");
            return (Criteria) this;
        }

        public Criteria andCreatetimeEqualTo(Date value) {
            addCriterionForJDBCDate("CREATETIME =", value, "createtime");
            return (Criteria) this;
        }

        public Criteria andCreatetimeNotEqualTo(Date value) {
            addCriterionForJDBCDate("CREATETIME <>", value, "createtime");
            return (Criteria) this;
        }

        public Criteria andCreatetimeGreaterThan(Date value) {
            addCriterionForJDBCDate("CREATETIME >", value, "createtime");
            return (Criteria) this;
        }

        public Criteria andCreatetimeGreaterThanOrEqualTo(Date value) {
            addCriterionForJDBCDate("CREATETIME >=", value, "createtime");
            return (Criteria) this;
        }

        public Criteria andCreatetimeLessThan(Date value) {
            addCriterionForJDBCDate("CREATETIME <", value, "createtime");
            return (Criteria) this;
        }

        public Criteria andCreatetimeLessThanOrEqualTo(Date value) {
            addCriterionForJDBCDate("CREATETIME <=", value, "createtime");
            return (Criteria) this;
        }

        public Criteria andCreatetimeIn(List<Date> values) {
            addCriterionForJDBCDate("CREATETIME in", values, "createtime");
            return (Criteria) this;
        }

        public Criteria andCreatetimeNotIn(List<Date> values) {
            addCriterionForJDBCDate("CREATETIME not in", values, "createtime");
            return (Criteria) this;
        }

        public Criteria andCreatetimeBetween(Date value1, Date value2) {
            addCriterionForJDBCDate("CREATETIME between", value1, value2, "createtime");
            return (Criteria) this;
        }

        public Criteria andCreatetimeNotBetween(Date value1, Date value2) {
            addCriterionForJDBCDate("CREATETIME not between", value1, value2, "createtime");
            return (Criteria) this;
        }

        public Criteria andCreatenameIsNull() {
            addCriterion("CREATENAME is null");
            return (Criteria) this;
        }

        public Criteria andCreatenameIsNotNull() {
            addCriterion("CREATENAME is not null");
            return (Criteria) this;
        }

        public Criteria andCreatenameEqualTo(String value) {
            addCriterion("CREATENAME =", value, "createname");
            return (Criteria) this;
        }

        public Criteria andCreatenameNotEqualTo(String value) {
            addCriterion("CREATENAME <>", value, "createname");
            return (Criteria) this;
        }

        public Criteria andCreatenameGreaterThan(String value) {
            addCriterion("CREATENAME >", value, "createname");
            return (Criteria) this;
        }

        public Criteria andCreatenameGreaterThanOrEqualTo(String value) {
            addCriterion("CREATENAME >=", value, "createname");
            return (Criteria) this;
        }

        public Criteria andCreatenameLessThan(String value) {
            addCriterion("CREATENAME <", value, "createname");
            return (Criteria) this;
        }

        public Criteria andCreatenameLessThanOrEqualTo(String value) {
            addCriterion("CREATENAME <=", value, "createname");
            return (Criteria) this;
        }

        public Criteria andCreatenameLike(String value) {
            addCriterion("CREATENAME like", value, "createname");
            return (Criteria) this;
        }

        public Criteria andCreatenameNotLike(String value) {
            addCriterion("CREATENAME not like", value, "createname");
            return (Criteria) this;
        }

        public Criteria andCreatenameIn(List<String> values) {
            addCriterion("CREATENAME in", values, "createname");
            return (Criteria) this;
        }

        public Criteria andCreatenameNotIn(List<String> values) {
            addCriterion("CREATENAME not in", values, "createname");
            return (Criteria) this;
        }

        public Criteria andCreatenameBetween(String value1, String value2) {
            addCriterion("CREATENAME between", value1, value2, "createname");
            return (Criteria) this;
        }

        public Criteria andCreatenameNotBetween(String value1, String value2) {
            addCriterion("CREATENAME not between", value1, value2, "createname");
            return (Criteria) this;
        }

        public Criteria andVadheadIsNull() {
            addCriterion("VADHEAD is null");
            return (Criteria) this;
        }

        public Criteria andVadheadIsNotNull() {
            addCriterion("VADHEAD is not null");
            return (Criteria) this;
        }

        public Criteria andVadheadEqualTo(BigDecimal value) {
            addCriterion("VADHEAD =", value, "vadhead");
            return (Criteria) this;
        }

        public Criteria andVadheadNotEqualTo(BigDecimal value) {
            addCriterion("VADHEAD <>", value, "vadhead");
            return (Criteria) this;
        }

        public Criteria andVadheadGreaterThan(BigDecimal value) {
            addCriterion("VADHEAD >", value, "vadhead");
            return (Criteria) this;
        }

        public Criteria andVadheadGreaterThanOrEqualTo(BigDecimal value) {
            addCriterion("VADHEAD >=", value, "vadhead");
            return (Criteria) this;
        }

        public Criteria andVadheadLessThan(BigDecimal value) {
            addCriterion("VADHEAD <", value, "vadhead");
            return (Criteria) this;
        }

        public Criteria andVadheadLessThanOrEqualTo(BigDecimal value) {
            addCriterion("VADHEAD <=", value, "vadhead");
            return (Criteria) this;
        }

        public Criteria andVadheadIn(List<BigDecimal> values) {
            addCriterion("VADHEAD in", values, "vadhead");
            return (Criteria) this;
        }

        public Criteria andVadheadNotIn(List<BigDecimal> values) {
            addCriterion("VADHEAD not in", values, "vadhead");
            return (Criteria) this;
        }

        public Criteria andVadheadBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("VADHEAD between", value1, value2, "vadhead");
            return (Criteria) this;
        }

        public Criteria andVadheadNotBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("VADHEAD not between", value1, value2, "vadhead");
            return (Criteria) this;
        }

        public Criteria andVadsegIsNull() {
            addCriterion("VADSEG is null");
            return (Criteria) this;
        }

        public Criteria andVadsegIsNotNull() {
            addCriterion("VADSEG is not null");
            return (Criteria) this;
        }

        public Criteria andVadsegEqualTo(BigDecimal value) {
            addCriterion("VADSEG =", value, "vadseg");
            return (Criteria) this;
        }

        public Criteria andVadsegNotEqualTo(BigDecimal value) {
            addCriterion("VADSEG <>", value, "vadseg");
            return (Criteria) this;
        }

        public Criteria andVadsegGreaterThan(BigDecimal value) {
            addCriterion("VADSEG >", value, "vadseg");
            return (Criteria) this;
        }

        public Criteria andVadsegGreaterThanOrEqualTo(BigDecimal value) {
            addCriterion("VADSEG >=", value, "vadseg");
            return (Criteria) this;
        }

        public Criteria andVadsegLessThan(BigDecimal value) {
            addCriterion("VADSEG <", value, "vadseg");
            return (Criteria) this;
        }

        public Criteria andVadsegLessThanOrEqualTo(BigDecimal value) {
            addCriterion("VADSEG <=", value, "vadseg");
            return (Criteria) this;
        }

        public Criteria andVadsegIn(List<BigDecimal> values) {
            addCriterion("VADSEG in", values, "vadseg");
            return (Criteria) this;
        }

        public Criteria andVadsegNotIn(List<BigDecimal> values) {
            addCriterion("VADSEG not in", values, "vadseg");
            return (Criteria) this;
        }

        public Criteria andVadsegBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("VADSEG between", value1, value2, "vadseg");
            return (Criteria) this;
        }

        public Criteria andVadsegNotBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("VADSEG not between", value1, value2, "vadseg");
            return (Criteria) this;
        }

        public Criteria andMaxsecondIsNull() {
            addCriterion("MAXSECOND is null");
            return (Criteria) this;
        }

        public Criteria andMaxsecondIsNotNull() {
            addCriterion("MAXSECOND is not null");
            return (Criteria) this;
        }

        public Criteria andMaxsecondEqualTo(BigDecimal value) {
            addCriterion("MAXSECOND =", value, "maxsecond");
            return (Criteria) this;
        }

        public Criteria andMaxsecondNotEqualTo(BigDecimal value) {
            addCriterion("MAXSECOND <>", value, "maxsecond");
            return (Criteria) this;
        }

        public Criteria andMaxsecondGreaterThan(BigDecimal value) {
            addCriterion("MAXSECOND >", value, "maxsecond");
            return (Criteria) this;
        }

        public Criteria andMaxsecondGreaterThanOrEqualTo(BigDecimal value) {
            addCriterion("MAXSECOND >=", value, "maxsecond");
            return (Criteria) this;
        }

        public Criteria andMaxsecondLessThan(BigDecimal value) {
            addCriterion("MAXSECOND <", value, "maxsecond");
            return (Criteria) this;
        }

        public Criteria andMaxsecondLessThanOrEqualTo(BigDecimal value) {
            addCriterion("MAXSECOND <=", value, "maxsecond");
            return (Criteria) this;
        }

        public Criteria andMaxsecondIn(List<BigDecimal> values) {
            addCriterion("MAXSECOND in", values, "maxsecond");
            return (Criteria) this;
        }

        public Criteria andMaxsecondNotIn(List<BigDecimal> values) {
            addCriterion("MAXSECOND not in", values, "maxsecond");
            return (Criteria) this;
        }

        public Criteria andMaxsecondBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("MAXSECOND between", value1, value2, "maxsecond");
            return (Criteria) this;
        }

        public Criteria andMaxsecondNotBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("MAXSECOND not between", value1, value2, "maxsecond");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}